#include <iostream>
#include "CurlTool.h"

using namespace std;

int main()
{
    if (-1 == LibCURL::Init())
    {
        printf("LibCURL Init Failed\n");
        return -1;
    }

    try
    {
        CurlTool ftp_t("172.26.2.61", "22755", "text", "cu3NqGSx");
        //CurlTool ftp_t("172.26.1.66", "21", "iosftp", "iosftp");
        //ftp_t.UploadFile("2000-11-11/a/b/c/1116810213.PDF","/home/zhenhe/project/CurlFtp/bin/Debug/1116810213.PDF");
        ftp_t.DownloadFile("2013-11-11/1116810213.PDF","/home/zhenhe/project/CurlFtp/bin/Debug/1116810213.PDF");
        //ftp_t.DeleteFile("2000-11-11/1116810213.PDF");

    }
    catch(std::exception& e)
    {
        printf("error is %s!",e.what());
    }


    LibCURL::Fini();
    return 0;
}
